<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateOnlineClassroomTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('online_classroom', function (Blueprint $table) {
            $table->increments('id');
            $table->string('title')->default('')->comment('标题');
            $table->string('description')->nullable()->comment('简介');
            $table->string('cover')->default('')->comment('封面图');
            $table->string('url')->default('')->comment('播放链接');
            $table->string('tag')->nullable()->comment('标签');
            $table->string('order')->default('1')->comment('排序');
            $table->string('status')->default('')->comment('状态');
            $table->timestamps();
            $table->softDeletes();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('online_classroom');
    }
}
